﻿ <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html><head>

	
		<meta http-equiv="content-type" content="text/html; charset=UTF-8">
		<link rel="shortcut icon" type="image/ico" href="http://www.sprymedia.co.uk/media/images/favicon.ico">
		
		<title>Using DataTable with row grouping plugin - Using Ajax Source</title>
		<style type="text/css" title="currentStyle">
			@import "media/css/demo_page.css";
			@import "media/css/demo_table.css";
			@import "media/css/themes/base/jquery-ui.css";
			@import "media/css/themes/smoothness/jquery-ui-1.7.2.custom.css";
		</style>

        <script src="media/js/jquery.min.js" type="text/javascript"></script>
        <script src="media/js/jquery.dataTables.min.js" type="text/javascript"></script>

        <script src="media/js/jquery-ui.js" type="text/javascript"></script>

        <script src="media/js/jquery.dataTables.rowGrouping.js" type="text/javascript"></script>

		<script type="text/javascript" charset="utf-8">
			$(document).ready( function () {
				$('#example').dataTable({"sAjaxSource": "ajax_source.js"}).rowGrouping();
				
			} );
		</script>
<script type="text/javascript">

  var _gaq = _gaq || [];
  _gaq.push(['_setAccount', 'UA-17838786-5']);
  _gaq.push(['_trackPageview']);

  (function() {
    var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
    ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
    var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
  })();

</script>
	</head>




<body id="dt_example">

		<div id="container">
			<a href="index.html">Home</a>
			<a href="http://code.google.com/p/jquery-datatables-column-filter/wiki/ColumnFilter">Wiki</a> 
			<h1 class="full_width big">

				JQuery DataTable Row Grouping - Ajax Source
			</h1>
			
			<h2>Preamble</h2>
			<p>
				DataTables Row Grouping add-in works even if you do not place rows in the table and load them via ajax source.
			</p>

			
	
			
			
			<h2>Live example</h2>







			<div id="demo">

<table cellpadding="0" cellspacing="0" border="0" class="display" id="example">
	<thead>
		<tr>
			<th>Rendering engine</th>
			<th>Browser</th>
			<th>Platform(s)</th>
			<th>Engine version</th>
			<th>CSS grade</th>
		</tr>
	</thead>
	<tfoot>
		<tr>

			<th>Rendering engine</th>
			<th>Browser</th>
			<th>Platform(s)</th>
			<th>Engine version</th>
			<th>CSS grade</th>
		</tr>
	</tfoot>
	<tbody>

	</tbody>
</table>

			</div>
			<div class="spacer"></div>

			
			

			
			<h2>Initialization code</h2>
			<p>Initialization code is as in standard case.</p>
			<pre>$(document).ready( function () {
		$('#example').dataTable({"sAjaxSource": "ajax_source.js"}).rowGrouping();
}
	</pre>
	


			<h2>Other examples</h2>

			<ul>

				<li><a href="default.html">Basic usage</a></li>
				<li><a href="letters.html">Group by letter</a></li>
				<li><a href="year.html">Group by year</a></li>
				<li><a href="customGroupOrdering.html">Custom group ordering</a></li>
				<li><a href="ajax.html">Ajax source grouping</a></li>
				<li><a href="collapsibleGroups.html">Collapsible/Expandable groups</a></li>
				<li><a href="accordion.html">Accordion Grouping</a></li>
				<li><a href="customization.html">Add-in customization</a></li>
				<li><a href="multipleTables.html">Multiple tables on the same page</a></li>
				<li><a href="twoLevelGrouping.html">Two level grouping</a></li>			</ul>
			
			<div id="footer" style="text-align:center;">
				<span style="font-size:10px;">
					DataTables Row Grouping Add-on &copy; Jovan Popovic 2011.<br>
					DataTables designed and created by <a href="http://www.sprymedia.co.uk">Allan Jardine</a> &copy; 2007-2011<br>
				</span>
			</div>
		</div>
	</body>





</html>